package com.java.advance.ticket.domain.pojo;

import org.apache.commons.lang3.builder.ToStringBuilder;

import java.util.Date;

/**
 * 车票信息实体类
 */
public class Ticket {
    private String ticketSeq;

    private Date ticketDate;

    private String fromStation;

    private String toStation;

    private Integer ticketStock;

    public Ticket() {
    }

    public Ticket(String ticketSeq, Date ticketDate, String fromStation, String toStation, Integer ticketStock) {
        this.ticketSeq = ticketSeq;
        this.ticketDate = ticketDate;
        this.fromStation = fromStation;
        this.toStation = toStation;
        this.ticketStock = ticketStock;
    }

    public String getTicketSeq() {
        return ticketSeq;
    }

    public void setTicketSeq(String ticketSeq) {
        this.ticketSeq = ticketSeq == null ? null : ticketSeq.trim();
    }

    public Date getTicketDate() {
        return ticketDate;
    }

    public void setTicketDate(Date ticketDate) {
        this.ticketDate = ticketDate;
    }

    public String getFromStation() {
        return fromStation;
    }

    public void setFromStation(String fromStation) {
        this.fromStation = fromStation == null ? null : fromStation.trim();
    }

    public String getToStation() {
        return toStation;
    }

    public void setToStation(String toStation) {
        this.toStation = toStation == null ? null : toStation.trim();
    }

    public Integer getTicketStock() {
        return ticketStock;
    }

    public void setTicketStock(Integer ticketStock) {
        this.ticketStock = ticketStock;
    }

    @Override
    public String toString() {
        return ToStringBuilder.reflectionToString(this);
    }
}